package cn.wolfcode.car.business.domain;

import cn.wolfcode.car.base.domain.User;
import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.Getter;
import lombok.Setter;
import org.springframework.format.annotation.DateTimeFormat;

import java.math.BigDecimal;
import java.util.Date;
@Setter
@Getter
public class StockBill {

    public static final Integer PUTSTORE = 0;
    public static final Integer OUTSTORE = 1;

    public static final Integer BILLSTATUS_NORMAL = 0;
    public static final Integer BILLSTATUS_CANCELLATION = -1;

    /** 单据流水号*/
    private Long id;

    /** 类型, 0 入库, 1 出库*/
    private Integer type;

    /** 仓库id*/
    private String storeId;
    private Store store;

    /** 出入库时间*/
    @JsonFormat(pattern = "yyyy-MM-dd",timezone = "GMT+8")
    @DateTimeFormat(pattern = "yyyy-MM-dd")
    private Date busiDate;

    /** 0 正常, -1 作废*/
    private Integer status;

    /** 操作时间*/
    @JsonFormat(pattern = "yyyy-MM-dd",timezone = "GMT+8")
    @DateTimeFormat(pattern = "yyyy-MM-dd")
    private Date operateDate;

    /** 操作人*/
    private Long operatorId;
    private User user;
    //总的数量
    private Integer totalAmounts;
    //总的价格
    private BigDecimal totalPrice;

    /** 备注*/
    private String remark;


}